<?php if (!is_object(Yii::app()->adminUser->worker)):?>
	<?php $model = new AdminLoginForm();?>
	<?php $form = $this->beginWidget('lib.widgets.CActiveFormAdv',array(
		'action' => Yii::app()->createUrl('provide/index/login')
	))?>
		<label>用户名：</label>
			<?php echo $form->textField($model,'username',array(
				'class'=>'bh-ly-jj-user bh-mR10'
			))?>
		<label>密码：</label>
			<?php echo $form->passwordField($model,'password',array(
				'class'=>'bh-ly-jj-user bh-mR10'
			))?>
		<?php echo CHtml::submitButton('登录',array(
			'class'=>'bh-ly-jj-login1',
			'name'=>'sub1',
		))?>
		<span class="bh-mlt10">
        	<a class="bh-mlt10" href="<?php echo Yii::app()->createUrl('misc/regType')?>">注册</a>
			<a href="<?php echo Yii::app()->createUrl('misc/findpass')?>">忘记密码</a>
            <a href="<?php echo Yii::app()->createUrl('help/list')?>">帮助</a>
		</span>
	<?php $this->endWidget();?>
<?php else:?>
<div class="bh-ly-jj-top_nav">
	<div class="bh-ly-jj-top_help bh-mR10 bh-fr">
    	<span class="font_cr3">欢迎<?php echo Yii::app()->adminUser->worker->profile->nickname?>来到旅游商城！<a href='<?php echo Yii::app()->createUrl('provide/index/logout')?>' class="bh-mlt90">注销</a></span>
		<span class="bh-mlt10">|<a href="<?php echo Yii::app()->createUrl('mall/center/ticket')?>" class="bh-mLtRt5">我的订单</a>|<a href="#" class="bh-mLtRt5">关于商城</a>|<a href="<?php echo Yii::app()->createUrl('help/list')?>" class="bh-mLtRt5">帮助中心</a></span>
	</div>
</div>
<?php endif;?>
